<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<fmt:setBundle basename="messages" />
<html>
<title><fmt:message key="PAGE_LOGIN" /></title>
<div id="loginForm">
	<span style="padding: 10px 20px;"><fmt:message key="LOGIN_OR" />
		<a href="action?command=register"><fmt:message key="REF_REGISTER" /></a></span>
	<form action="action" method="post">

		<input type="hidden" name="command" value="login" /> <br> <input
			type="text" name="login"
			placeholder="<fmt:message key="INPUT_LOGIN"/>" required
			pattern="^[а-яА-ЯёЁa-zA-Z0-9]+$" id="fieldInput"> <br> <input
			type="password" name="password"
			placeholder="<fmt:message key="INPUT_PASSWORD"/>" required
			id="fieldInput" /> <br> <input type="submit"
			value="<fmt:message key="BUTTON_LOGIN"/>" id="button" />
	</form>

	<div id="errorMessage">
		<c:if test="${not empty errorMessage}">
			<fmt:message key="${errorMessage}" />
		</c:if>
	</div>
</div>
</html>